<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>ajax使用</title>
</head>
<body>
	<script type="text/javascript">
		function toAjax() {
			// 初始化XMLHttpRequest
			var http_request;
			if (window.XMLHttpRequest) {
				http_request = new XMLHttpRequest();
			} else if (window.ActiveXObject) {
				try {
					http_request = new ActiveXObject("Msxml2.XMLHTTP");
				} catch (e) {
					try {
						http_request = new ActiveXObject("Mcrosoft.XMLHTTP");
					} catch (e) { }
				}
			}
		}
	
	</script>
</body>
</html>